/*
 * MemoryDocumentEnd.java
 *
 * Created on August 22, 2002, 4:45 PM
 */

package org.infoset.xml.memory;

import org.infoset.xml.*;
/**
 *
 * @author  R. Alexander Milowski
 */
public class MemoryDocumentEnd extends MemoryItem implements DocumentEnd {
   
   int line;
   int column;
   
   /** Creates a new instance of MemoryDocumentEnd */
   public MemoryDocumentEnd(Infoset infoset) {
      super(infoset,0,null);
      this.line = 0;
      this.column = 0;
   }
   
   public Item copyOfItem(boolean copyAll) {
      MemoryDocumentEnd end = new MemoryDocumentEnd(infoset);
      end.line = line;
      end.column = column;
      return end;
   }
   
   /** Returns the type of type node.
    */
   public ItemType getType() {
      return ItemType.DocumentEndItem;
   }
   
   protected void setIndex(int i) {
   }
   
   public int getColumn() {
      return column;
   }   

   public int getLine() {
      return line;
   }
   
   public void setColumn(int column) {
      this.column = column;
   }
   
   public void setLine(int line) {
      this.line = line;
   }
   public String toString() {
      return "[end document]";
   }
   
}
